home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 15
/
Aminet 15 - Nov 1996.iso
/
Aminet
/
mods
/
chip
/
MelonZoolMus.lha
/
MelonZoolMus.asm
< prev
next >
Wrap
Assembly Source File
|
1992-09-03
|
6KB
|
277 lines
; $VER MelonZoolMus.asm (31.9.96)
; by Kyzer/CSG
incdir inc: ; change as needed
include misc/deliplayer.i
SECTION player,code
PLAYERHEADER tags
dc.b "$VER: CUST.MelonZoolMus (31.9.96)",0
even
tags dc.l DTP_CustomPlayer,1
dc.l DTP_InitPlayer,initply
dc.l DTP_EndPlayer,endply
dc.l DTP_InitSound,mt_init
dc.l DTP_Interrupt,mt_music
dc.l DTP_EndSound,mt_end
dc.l TAG_DONE
initply move.l dtg_AudioAlloc(a5),a0
jmp (a0)
endply move.l dtg_AudioFree(a5),a0
jmp (a0)
mt_init movem.l d0-7/a0-6,-(sp)
lea smp0,a2
moveq #$10,d0
lea $dff0a0,a3
lea trk0(pc),a0
lea pos0(pc),a1
bsr.s .set
lea trk1(pc),a0
lea pos1(pc),a1
bsr.s .set
lea trk2(pc),a0
lea pos2(pc),a1
bsr.s .set
lea trk3(pc),a0
lea pos3(pc),a1
bsr.s .set
move.w #$800f,$dff096
movem.l (sp)+,d0-7/a0-6
rts
.set move.l a2,(a0)
clr.l 8(a0)
clr.l 14(a0)
clr.l 16(a0)
move.l a3,26(a0)
move.l a1,30(a0)
move.l (a1),34(a0)
move.l a1,38(a0)
move.l 4(a1),46(a0)
move.l a2,(a3)
move.w d0,4(a3)
clr.l 6(a3)
add.l d0,a3
rts
mt_end move.w #15,$dff096
rts
mt_music
movem.l d0-7/a0-6,-(sp)
lea trk0(pc),a0
bsr.s .ply
lea trk1(pc),a0
bsr.s .ply
lea trk2(pc),a0
bsr.s .ply
lea trk3,a0
bsr.s .ply
movem.l (sp)+,d0-7/a0-6
rts
.ply subq.w #1,14(a0)
bpl .g
clr.w 52(a0)
clr.w 54(a0)
.a move.l 34(a0),a1
move.l 46(a0),d3
moveq #0,d4
move.w (a1),d4
cmp.w #128,d4
bne.s .b
clr.l 8(a0)
move.l 2(a1),(a0)
addq.l #6,34(a0)
move.l 2(a1),d5
move.l 26(a0),a3
move.l d5,(a3)
bra.s .a
.b cmp.w #129,d4
bne.s .c
move.l (a0),a3
move.l 2(a1),86(a3)
move.l 6(a1),90(a3)
add.l #10,34(a0)
bra.s .a
.c cmp.w #130,d4
bne.s .d
move.w #1,54(a0)
bra.s .e
.d add.w d4,d3
tst.l d4
bne.s .e
addq.l #8,30(a0)
move.l 30(a0),a2
move.l 4(a2),46(a0)
move.l (a2),34(a0)
bne.s .a
move.l 38(a0),30(a0)
move.l 30(a0),a2
move.l 4(a2),46(a0)
move.l (a2),34(a0)
bra .a
.e tst.w 54(a0)
bne.s .f
clr.l 4(a0)
clr.w 56(a0)
move.w d3,50(a0)
.f move.w 2(a1),14(a0)
subq.w #1,14(a0)
addq.l #4,a1
move.l a1,34(a0)
.g move.l 26(a0),a2
move.l (a0),a3
move.w 24(a0),d0
subq.w #1,d0
add.l d0,d0
lea vib,a4
move.w (a4,d0.w),d1
move.w 94(a3),d0
beq.s .k
cmp.w 42(a0),d1
bcs.s .i
add.w d0,42(a0)
cmp.w 42(a0),d1
bhi.s .h
move.w d1,42(a0)
.h bra.s .el
.i sub.w d0,42(a0)
cmp.w 42(a0),d1
bcs.s .j
move.w d1,42(a0)
.j bra.s .el
.k add.w 52(a0),d1
move.w d1,42(a0)
.el move.l (a0),a3
add.l #86,a3
move.l 18(a0),d1
moveq #0,d2
move.b (a3,d1.l),d2
bpl.s .m
neg.b d2
moveq #0,d3
move.w 50(a0),d3
sub.w d2,d3
move.w d3,d2
bra.s .n
.m add.w 50(a0),d2
.n move.w d2,24(a0)
addq.l #1,18(a0)
cmp.l #8,18(a0)
bne.s .o
clr.l 18(a0)
.o move.l (a0),a3
tst.w 12(a0)
beq.s .p
clr.w 12(a0)
moveq #0,d2
move.b 85(a3),d2
move.w 42(a0),d1
add.w d2,d1
move.w d1,42(a0)
bra.s .q
.p move.w #-1,12(a0)
moveq #0,d2
move.b 85(a3),d2
move.w 42(a0),d1
sub.w d2,d1
move.w d1,42(a0)
.q moveq #0,d2
move.w 96(a3),d2
sub.w d2,52(a0)
moveq #0,d0
move.w 42(a0),d0
move.w 98(a3),d1
beq.s .s
bmi.s .r
sub.w 56(a0),d0
bra.s .s
.r add.w 56(a0),d0
.s move.l 8(a0),d1
subq.b #1,16(a0)
bpl.s .u
addq.l #1,d1
cmp.l #32,d1
bne.s .t
moveq #0,d1
.t move.l d1,8(a0)
move.b 82(a3),16(a0)
.u lea 50(a3),a4
moveq #0,d2
move.b (a4,d1.l),d2
ext.w d2
tst.b 84(a3)
beq.s .v
add.w d2,d0
.v move.w d0,6(a2)
moveq #0,d2
move.l (a0),a2
moveq #0,d0
moveq #0,d1
move.b 48(a2),d0
move.b 49(a2),d1
cmp.l 4(a0),d1
beq.s .z
tst.l d0
beq.s .ew
cmp.l 4(a0),d0
bne.s .ew
tst.w 54(a0)
beq.s .z
.ew move.l 4(a0),d2
add.w d2,d2
lea 32(a2),a3
moveq #0,d3
moveq #0,d4
move.b (a3,d2.w),d3
move.b 1(a3,d2.w),d4
cmp.w 56(a0),d4
bhi.s .y
sub.w d3,56(a0)
cmp.w 56(a0),d4
ble.s .x
move.w d4,56(a0)
addq.l #1,4(a0)
.x bra.s .z
.y add.w d3,56(a0)
cmp.w 56(a0),d4
bhi.s .z
move.w d4,56(a0)
addq.l #1,4(a0)
.z moveq #0,d1
move.w 56(a0),d1
asr #2,d1
move.l 26(a0),a1
move.w d1,8(a1)
rts
trk0 dcb.b 58,0
trk1 dcb.b 58,0
trk2 dcb.b 58,0
trk3 dcb.b 58,0
pos0 dc.l pat1-2,1,pat1-2,-3,pat1-2,-8,pat2-2,-1,0,0
pos1 dc.l pat3-2,1,0,0
pos2 dc.l pat4-2,0,0,0
pos3 dc.l pat8-2,1,pat5-2,1,pat5-2,1,pat7-2,1,pat7-2,1,pat6-2,1,pat6-2,1,0,0,$80 ; $80 is for next part! :)
pat1 dc.l smp0,$810000,0,$19,$C0019,$180019,$60025,$60019,$C0019,$240000,$80
pat2 dc.l smp0,$810000,0,$19,$C0019,$180019,$60017,$60019,$C0019,$240000,$80
pat3 dc.l smp1,$810003,$7000003,$700003D,$600081,$30800,$30800,$3D0060,$81FE03,$7FEFE03,$7FE003D,$600081,$FE0205FE,$FE0205FE,$3D0060,$80
pat4 dc.l smp2,$810000,0,$82,$18002D,$C0082,$24002D,$C002D,$6002D,$60082,$18002D,$C0082,$24002D,$8002C,$8002B,$80000,$80
pat5 dc.l smp3,$810000,0,$31,$300034,$C0033,$C0031,$C002F,$C002D,$300034,$C0033,$C0031,$C002F,$C0034,$300034,$C0033,$C0031,$C002F,$C0036,$180033,$180031,$18002F,$180000,$80
pat6 dc.l smp3,$810000,0,$31,$300038,$C0038,$C0038,$C0036,$180038,$6C0034,$C0034,$180034,$180034,$C0036,$180033,$180031,$18002F,$180000,$80
pat7 dc.l smp3,$810000,0,$31,$480038,$180036,$C0034,$C0031,$600034,$C0034,$180034,$180034,$C0036,$180033,$180031,$18002F,$180000,$82
pat8 dc.l $1800000,0,0,0,0
section module,data_c
smp0 dc.l $80889098,$A0A8B0B8,$C0C8D0D8,$E0E8F0F8,$81018,$20283038,$40485058,$60687078,$FFFF0E00,0,0,0,$20002,$4060806,$40200FE,$FCFAF8FA,$FCFE0002,$4060806,$40200FE,$FCFAF8FA,$FCFE0000,$1000000,0,0,0
smp1 dc.l $00F0E0D0,$C0B0A090,$8090A0B0,$C0D0E0F0,$00102030,$40506070,$7F706050,$40302010,$96960000,0,0,0,$00010002,$04060806,$040200FE,$FCFAF8FA,$FCFE0002,$04060806,$040200FE,$FCFAF8FA,$FCFE0000,0,0,0,0,0,0,0,0,0
smp2 dc.l $80808080,$80808080,$80808080,$80808080,$7F7F7F7F,$7F7F7F7F,$7F7F7F7F,$7F7F7F7F,$FFFF1E00,0,0,0,$20002,$4060806,$40200FE,$FCFAF8FA,$FCFE0002,$4060806,$40200FE,$FCFAF8FA,$FCFE0000,0,0,0,$FFE20000
smp3 dc.l $80808080,$80808080,$80808080,$80808080,$7F7F7F7F,$7F7F7F7F,$7F7F7F7F,$7F7F7F7F,$28AF0A64,$06000000,0,0,$02030002,$04060806,$040200FE,$FCFAF8FA,$FCFE0002,$04060806,$040200FE,$FCFAF8FA,$FCFE0000,0,0,0,0
vib dc.l $1AC01940,$17D01680,$15301400,$12E011D0,$10D00FE0,$F000E20,$D600CA0,$BE80B40,$A980A00,$97008E8,$86807F0,$7800710,$6B00650,$5F405A0,$54C0500,$4B80474,$43403F8,$3C00388,$3580328,$2FA02D0,$2A60280,$25C023A
dc.l $21A01FC,$1E001C4,$1AC0194,$17D0168,$1530140,$12E011D,$10D00FE,$F000E2,$D600CA,$BE00B4,$AA00A0,$97008F,$87007F
dc.b "Kyzer/CSG, 49 Fairview Road, AB22 8ZG, Scotland."